/*****************************************************************
Copyright (c) 2011 - 2017 Qualcomm Technologies International, Ltd.

PROJECT
    source
    
FILE NAME
    source_power.h

DESCRIPTION
    Handles power readings when running as a self powered device.    

*/


#ifndef _SOURCE_POWER_H_
#define _SOURCE_POWER_H_


/* VM headers */
#include <csrtypes.h>
#include "source_private.h"

/***************************************************************************
Function definitions
****************************************************************************
*/

#ifdef INCLUDE_POWER_READINGS

/****************************************************************************
NAME    
    power_init

DESCRIPTION
    Initialises the power manager.
 
*/
#ifdef INCLUDE_POWER_READINGS
void power_init(void);
#else
#define power_init() ((void)(0))
#endif

#endif /* INCLUDE_POWER_READINGS */


/****************************************************************************
NAME    
    power_is_charger_connected
    
DESCRIPTION
      This function checks  if the charger is connected  or not

RETURNS
    TRUE, if the charger is connected.
    FALSE, if otherwise.
    
*/
bool power_is_charging(void);

void SourcenNotifyBatteryLow(void);

void SourceDisableBatteryLowNotify(void);

void power_show_battery_level(void);

void power_show_charging_led(void);

void power_show_battery_level_normal(void);
#endif /* _SOURCE_POWER_H_ */


